package com.bw.classfiy.mvvm.model;

import com.bw.mvvm.entity.BaseEntity;
import com.bw.mvvm.mvvm.model.BaseModel;
import com.bw.mvvm.network.ChangeFunction;
import com.bw.mvvm.network.load.HttpEnum;
import com.bw.mvvm.network.load.HttpFactory;


import io.reactivex.Observable;
import okhttp3.RequestBody;

public class ClassFiyModel extends BaseModel {

    public Observable<BaseEntity> requestTable(RequestBody body){
        return HttpFactory.create(HttpEnum.TokenSign)
                .getRetrofit()
                .create(Api.class).requestOne(body).map(new ChangeFunction<>());
    }

    public Observable<BaseEntity> requestValue(RequestBody body){
        return HttpFactory.create(HttpEnum.TokenSign)
                .getRetrofit()
                .create(Api.class).requestclassfiy(body).map(new ChangeFunction<>());
    }


}
